package com.systemframework.sys.dto.request;

import com.systemframework.sys.dto.request.common.PageResponseDTO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * @author summer
 * @date 2023-04-04 17:43
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class EmailAccountRequestDTO extends PageResponseDTO implements Serializable {

    private Integer id;

    @NotBlank(message = "邮箱不能为空")
    @Email(message = "邮箱格式不对")
    private String email;

    @NotBlank(message = "用户名不能为空")
    private String username;

    @NotBlank(message = "密码不能为空")
    private String password;

    @NotNull(message = "端口不能为空")
    private Integer port;

    @NotBlank(message = "SMTP服务器域名不能为空")
    private String realm;

    private Integer enabledSsl;
}
